package com.webservice.xmloper.managercode;

import java.io.ByteArrayInputStream;
import java.io.InputStream;

import com.thoughtworks.xstream.XStream;

public class ParseManagerCode {
	
	/**
	 * 解析管理指令（参数是字符串）
	 */
	public static ManagerCode parseManagerCodeByString(String xmlString) throws Exception{
		XStream xs = new XStream();
		xs.processAnnotations(ManagerCode.class);
		InputStream myIn=new ByteArrayInputStream(xmlString.getBytes());
		return (ManagerCode) xs.fromXML(myIn);
	}
}	
